package com.coamc.xlsunit;

import java.util.Map.Entry;

import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;
import org.apache.poi.ss.usermodel.Workbook;

/**
 * ##includeSheet /base.xls 初始化静态数据
 * 
 * @author lijiazhi
 *
 */
public class XLSIncludeSheet {
	String file;
	String targetSheet;
	XLSParser parser = null;
	String cmd ;

	public XLSIncludeSheet(XLSParser parser, String paras) {
		String[] loc = paras.split(" ");
		cmd = loc[0];
		file = loc[1];
		targetSheet = loc[2];
		this.parser = parser;

	}

	public void doInclude(VariableTable vars) {
		XLSParser newParser = new XLSParser(parser.loader, file, parser.db,parser.rowFactory);
		newParser.init(vars, targetSheet);

	}
}
